package com.chart.web.controller.chart;

import com.chart.common.core.domain.AjaxResult;
import com.chart.common.core.domain.entity.ChartRecord;
import com.chart.system.service.IChartRecordService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/chartRecord")
public class ChartRecordController {
    @Autowired
    private IChartRecordService chartRecordService;

    // 查询所有图表记录
    @GetMapping("/list")
    public AjaxResult listAllChartRecords() {
        List<ChartRecord> chartRecords = chartRecordService.list();
        return AjaxResult.success(chartRecords);
    }


}
